import { defHttp } from '../http'
import type { CommonAPI } from '../model/_utils'
import type { UserModel } from '../model/user'
// import type { BaseListResp } from './response'

export const userInfoApi = () => defHttp.get<UserModel>('/user/info')

// export const userListApi = (params: Recordable = {}) =>
//   defHttp.get<BaseListResp<UserModel[]>>('/user/list', { params })
export const userListApi: CommonAPI<'/v1/users', 'get'> = params =>
  defHttp.get(`/users`, { params })
